(global.webpackJsonp = global.webpackJsonp || []).push([ [ "pages/home/components/address-card-popup/index" ], {
    "1ee4": function(e, n, a) {
        a.r(n);
        var d = a("bfa0"), o = a.n(d);
        for (var t in d) [ "default" ].indexOf(t) < 0 && function(e) {
            a.d(n, e, function() {
                return d[e];
            });
        }(t);
        n.default = o.a;
    },
    "212e": function(e, n, a) {},
    "261c": function(e, n, a) {
        var d = a("212e");
        a.n(d).a;
    },
    bfa0: function(e, n, a) {
        (function(e) {
            var d = a("4ea4").default;
            Object.defineProperty(n, "__esModule", {
                value: !0
            }), n.default = void 0;
            var o = a("fd0e"), t = d(a("0613")), c = a("665c"), r = a("05dc"), s = a("48b8"), i = a("cee8"), u = a("009c"), l = {};
            l.props = {
                options: {
                    type: Object,
                    default: function() {
                        return {};
                    }
                }
            }, l.setup = function(n, a) {
                var d = a.emit;
                (0, o.onBeforeMount)(function() {
                    d("loaded", {
                        isShowPop: b
                    });
                });
                var l = (0, c.useState)().address, f = (0, c.useGetters)().isCanOrder, p = (0, o.reactive)({
                    addrInfo: {},
                    addrInfoName: "",
                    addrInfoDetail: "",
                    addrInfoUser: "",
                    addrIndex: 0
                }), m = (0, o.ref)(!1);
                function v() {
                    e.hideTabBar(), setTimeout(function() {
                        m.value = !0;
                    }, 150);
                    var n = (0, c.useState)().userAddressCardType;
                    (0, r.statistics)("address_card_page_expo", {
                        page_name: "收/发货地址半页",
                        page_from: "share" === n.value ? "微信卡片" : "scan" === n.value ? "扫一扫" : ""
                    });
                }
                function _() {
                    var e = 0 === p.addrIndex && function() {
                        var e, n = (null === (e = l.value) || void 0 === e ? void 0 : e[0]) || {}, a = l.value[t.default.state.address.length - 1].city_id || "", d = n.city_id || "";
                        return Number(a) !== Number(d);
                    }();
                    if (f.value && e) {
                        var n, a = (null === (n = t.default.getters.selectedVehicle) || void 0 === n ? void 0 : n.name) || "";
                        t.default.commit("setState", {
                            oldSelectedService: t.default.state.selectedService,
                            oldSelectedVehicleName: a,
                            selectedStd: []
                        });
                    }
                    (0, o.nextTick)(function() {
                        d("change", {
                            cityChange: e
                        });
                    });
                }
                function b() {
                    return m.value;
                }
                return e.$on("open-address-card-popup", function(e) {
                    console.info("user-address-card: emit->", e), p.addrInfo = e, function(e) {
                        var n = e.addr_info, a = void 0 === n ? {} : n, d = e.house_number, o = void 0 === d ? "" : d, t = e.contacts_name, c = void 0 === t ? "" : t, r = e.contacts_phone_no, i = void 0 === r ? "" : r, u = o ? "(".concat(o, ")") : "", l = " ".concat(null == a ? void 0 : a.name).concat(u);
                        p.addrInfoName = (null == l ? void 0 : l.length) > 21 ? (null == l ? void 0 : l.substring(0, 21)) + "..." : l, 
                        p.addrInfoDetail = null == a ? void 0 : a.addr, p.addrInfoUser = "".concat(c, " ").concat((0, 
                        s.formatPhone)(i));
                    }(e), v();
                }), e.$on("hide-address-card-popup", function() {
                    _(), d("change"), i.$loading.hide(), m.value = !1, e.showTabBar();
                }), e.$on("user_address_card_login_callback", function(e) {
                    (0, u.useAddressCodeInfo)();
                }), (0, o.onUnmounted)(function() {
                    e.$off("open-address-card-popup"), e.$off("hide-address-card-popup"), e.$off("user_address_card_login_callback");
                }), Object.assign({
                    data: p,
                    isShow: m,
                    onClickCloseBtn: function() {
                        (0, r.statistics)("address_card_click", {
                            page_name: "收/发货地址半页",
                            module_name: "关闭半页"
                        }), e.$emit("address-card-popup-submit-callback", {
                            type: "close"
                        });
                    },
                    changeStartAddress: function() {
                        (0, r.statistics)("address_card_click", {
                            page_name: "收/发货地址半页",
                            module_name: "填入装货地"
                        }), (0, i.$loading)(), p.addrIndex = 0, e.$emit("address-card-popup-submit-callback", {
                            type: "start",
                            index: 0
                        });
                    },
                    changeEndAddress: function() {
                        (0, r.statistics)("address_card_click", {
                            page_name: "收/发货地址半页",
                            module_name: "填入卸货地"
                        }), (0, i.$loading)();
                        var n = t.default.state.address.length - 1;
                        p.addrIndex = n, e.$emit("address-card-popup-submit-callback", {
                            type: "end",
                            index: n
                        });
                    }
                }, {
                    isShowPop: b
                });
            }, l.components = Object.assign({
                BottomPopup: function() {
                    Promise.all([ a.e("common/vendor"), a.e("components/bottom-popup/index") ]).then(function() {
                        return resolve(a("54a1"));
                    }.bind(null, a)).catch(a.oe);
                }
            }, l.components);
            var f = l;
            n.default = f;
        }).call(this, a("543d").default);
    },
    df96: function(e, n, a) {
        a.r(n);
        var d = a("f152"), o = a("1ee4");
        for (var t in o) [ "default" ].indexOf(t) < 0 && function(e) {
            a.d(n, e, function() {
                return o[e];
            });
        }(t);
        a("261c");
        var c = a("f0c5"), r = Object(c.a)(o.default, d.b, d.c, !1, null, "9dd4ac7a", null, !1, d.a, void 0);
        n.default = r.exports;
    },
    f152: function(e, n, a) {
        a.d(n, "b", function() {
            return d;
        }), a.d(n, "c", function() {
            return o;
        }), a.d(n, "a", function() {});
        var d = function() {
            this.$createElement;
            this._self._c;
        }, o = [];
    }
} ]), (global.webpackJsonp = global.webpackJsonp || []).push([ "pages/home/components/address-card-popup/index-create-component", {
    "pages/home/components/address-card-popup/index-create-component": function(e, n, a) {
        a("543d").createComponent(a("df96"));
    }
}, [ [ "pages/home/components/address-card-popup/index-create-component" ] ] ]);